package com.wanghengzhi.kata;

/**
 *
 * @author wanghengzhi
 * @since 2021/11/4 22:24
 */
public class RegularAbstractGoods extends AbstractGoods {
    public RegularAbstractGoods(String name, double quality, int sellIn) {
        super(name, quality, sellIn);
    }

    @Override
    public void updateByDay() {
        decreaseQuality();
        decreaseSellIn();
        if (isExpired()) {
            decreaseQuality();
        }
    }
}
